﻿@model LastPostModel
@using Nop.Core.Infrastructure;
@using Nop.Web.Models.Boards;
@using Nop.Web.Framework;
@using Nop.Services.Customers;
@using Nop.Services.Forums;
@using Nop.Services.Helpers;
@using Nop.Services.Seo;
@if (@Model.Id > 0)
{
    <div class="LastPost">
        @Model.PostCreatedOnStr<br />
        @if (Model.ShowTopic)
        {
            <text>@T("Forum.In"):</text>
            @Html.RouteLink(Model.ForumTopicSubject, "TopicSlug", new { id = @Model.ForumTopicId, slug = @Model.ForumTopicSeName })
            <br />
        }
        @if (@Model.CustomerId > 0)
        {
            if (Model.AllowViewingProfiles && !Model.IsCustomerGuest)
            {
                @T("Forum.By")<text>:</text> @Html.RouteLink(Model.CustomerName, "CustomerProfile", new { Id = Model.CustomerId })
            }
            else
            {
                @T("Forum.By")<text>:</text> @Model.CustomerName
            }
        }
    </div>
}
else
{
    <div class="nopost">
        @T("Forum.NoPosts")
    </div>
}
